﻿namespace Automated_Teller_Machine
{
    public abstract class Transaction
    {
       private int accountNumber; // account involved in the transaction
       private Screen userScreen; // reference to ATM's screen
       private BankDatabase database; // reference to account info database
 
       
      public Transaction( int userAccount, Screen theScreen,
         BankDatabase theDatabase )
      {
         accountNumber = userAccount;
         userScreen = theScreen;
         database = theDatabase;
      } 

      
      public int AccountNumber
      {
         get
         {
            return accountNumber;
         }
      }
      
      public Screen UserScreen
      {
         get
         {
            return userScreen;
         } 
      } 
      
      public BankDatabase Database
      {
         get
         {
            return database;
         } 
      } 
      
      public abstract void Execute(); 
   } 
}
